package com.woniuxy.common.enums;

import lombok.Getter;

@Getter
public enum ResultCode {
    // 枚举对象：描述状态码、状态码的描述
    SUCCESS(200,"操作成功"),
    FAIL(500,"操作失败"),
    /**
     * 参数错误：30001-39999
     */
    PARAM_IS_INVALID(30001, "参数无效"),
    PARAM_IS_BLANK(30002, "参数为空"),
    PARAM_TYPE_BIND_ERROR(30003, "参数类型错误");
    private int code;
    private String message;
    // 枚举构造函数，默认是private
     ResultCode(int code, String message) {
        this.code = code;
        this.message = message;
    }
}
